#ifndef OSPOTLIGHT_H
#define OSPOTLIGHT_H

#include "light.h"

class OSpotLight : public OLight
{
    Q_OBJECT

    Q_PROPERTY(float innerAng READ innerAng WRITE setInnerAng);
    Q_PROPERTY(float outerAng READ outerAng WRITE setOuterAng);
    Q_PROPERTY(float fallOff READ fallOff WRITE setFallOff);

public:
    explicit OSpotLight(QObject *parent = 0);

    void setLight(Ogre::Light* light){
        OLight::setLight(light);
        m_light->setSpotlightRange(Ogre::Degree(m_innerAng), Ogre::Degree(m_outerAng), m_fallOff);
    }

    // ---- radiuse

    float innerAng() const ;

    void setInnerAng(float ang);

    float outerAng() const;

    void setOuterAng(float ang);

    float fallOff() const ;

    void setFallOff(float ang);

signals:

public slots:

protected:
    float m_innerAng;
    float m_outerAng;
    float m_fallOff;

};

#endif // OSPOTLIGHT_H
